




<div class="x-body">
    <div class="layui-row">
        <form class="layui-form layui-col-md12 x-so">
            <input class="layui-input"  autocomplete="off" placeholder="开始日" name="date1"  value="{:input('date1')}" id="start">
            <input class="layui-input"  autocomplete="off" placeholder="截止日" name="date2"  value="{:input('date2')}" id="end">
            <input type="text" name="mobile"  placeholder="用户名|UID|手机号" autocomplete="off" value="{:input('mobile')}"  class="layui-input">
            <div class="layui-input-inline">
                <select name="type">
                    <option value="" >全部类型</option>
                    <option value="1" {notempty name="param['type']"}{if condition="$param['type'] eq 1"} selected="selected" {/if}{/notempty} >升级</option>
                    <option value="2" {notempty name="param['type']"}{if condition="$param['type'] eq 2"} selected="selected" {/if}{/notempty} >降级</option>

                </select>
            </div>
            <div class="layui-input-inline">
                <select name="level_id">
                    <option value="" >全部等级</option>
                    {volist name='level' id='vo'}
                    <option value="{$vo['id']}" {notempty name="param['level_id']"}{if condition="$param['level_id'] eq $vo['id']"} selected="selected" {/if}{/notempty} >{$vo['level_name']}</option>
                    {/volist}
                </select>
            </div>
            <button class="layui-btn"  id="search"  url="{:url('level_log')}"  lay-submit="" lay-filter="sreach"><i class="layui-icon">&#xe615;</i></button>
        </form>
    </div>
    <xblock>
        <!--<button class="layui-btn layui-btn-danger" onclick="delAll()"><i class="layui-icon"></i>批量删除</button>-->

        <span class="x-right" style="line-height:40px">共有数据：{$list.count} 条</span>
    </xblock>
    <table class="layui-table x-admin">
        <thead>
        <tr>

            <th>序号</th>
            <th>用户名</th>
            <th>UID</th>
            <th>手机号</th>
            <th>类型</th>
            <th>等级</th>
            <th>时间</th>

            <!--<th>操作</th>-->
        </thead>
        {notempty name='list.list'}
        <tbody>
        {volist name='list.list' id='vo' key="k"}
        <tr>

            <td>{$k}</td>
            <td>{$vo.username}</td>
            <td>{$vo.user_id}</td>
            <td>{$vo.mobile}</td>
            <td>{$vo.type_text}</td>
            <td>{$vo.leve.level_name}</td>
            <td>{$vo.create_time}</td>


        </tr>
        {/volist}
        {else/}
        <tbody><tr class="odd"><td colspan="12" class="text-center" valign="top">{:config('empty_list_describe')}</td></tr></tbody>
        {/notempty}

        </tbody>
    </table>
    <div class="page">
        {notempty name='list'}   {$list.list->render()}{/notempty}
    </div>

</div>
<script>
    layui.use('form', function(){
        form = layui.form;

    });
    function delAll (argument) {

        var data = tableCheck.getData();


        layer.confirm('确认要删除吗？',function(index){
            //捉到所有被选中的，发异步进行删除
            //监听提交
            var url="{:url('setStatus')}";
            $.post(url,{ids:data,status:-1},function (d) {
                if(d.code==1){
                    $(".layui-form-checked").not('.header').parents('tr').remove();
                    layer.msg('删除成功', {icon: 1});

                }else{
                    layer.msg(d.msg);

                }
            },'json');



        });
    }
</script>

</body>

</html>
